<?php /* Smarty version Smarty-3.0.7, created on 2011-07-14 17:40:34
         compiled from ".\templates\contacto.tpl.html" */ ?>
<?php /*%%SmartyHeaderCode:101734e1f54424ffff9-07198471%%*/if(!defined('SMARTY_DIR')) exit('no direct access allowed');
$_smarty_tpl->decodeProperties(array (
  'file_dependency' => 
  array (
    '6698ef9a39e61f3d63e4a0b689e55a9f74633a00' => 
    array (
      0 => '.\\templates\\contacto.tpl.html',
      1 => 1308778770,
      2 => 'file',
    ),
  ),
  'nocache_hash' => '101734e1f54424ffff9-07198471',
  'function' => 
  array (
  ),
  'has_nocache_code' => false,
)); /*/%%SmartyHeaderCode%%*/?>
<script language="javascript" type="text/javascript">
function formvalidacion()
{
	var form = document.contactos;
	if(form.nombre.value == "")
	{
            alert( "Ingresar Nombre:" );
            return false;
	}
	else if(form.apellidos.value == "")
	{
            //document.title = "Gestionar Contacto";
            alert( "Ingresar Apellidos:");
            return false;
	}else if(form.email.value == "")
	{
            alert( "Ingresar E-mail:" );
            return false;
	}
}
</script>
<div align="justify" style="font-size:12px; color:#222222; padding: 5px 150px 30px 150px;">
        
    <div style="border-bottom: 1px solid #DDD; padding: 8px 0px 0px 0px;">
        <h2 style="font-size:12px; color:#222222;"><?php echo $_smarty_tpl->getVariable('titulo')->value;?>
</h2>
    </div>
    
   <div>
   <form action="contactos.php?do=<?php echo $_smarty_tpl->getVariable('dohacer')->value;?>
" method="post" enctype="multipart/form-data" name="contactos" id="contactos">
       <table align="center" border="0" cellspacing="0" cellpadding="0" width="70%" class="small">
           <tbody>
            <tr>
                <td colspan="2" style="padding:10px 0px 10px 0px">
                   <div align="center">
                    <input title="<?php echo $_smarty_tpl->getVariable('txtboton')->value;?>
 [Alt+S]" accesskey="S" class="save" type="submit" name="button" value="<?php echo $_smarty_tpl->getVariable('txtboton')->value;?>
" style="width:100px" onclick="return( formvalidacion());">
                    <input title="Cancelar [Alt+X]" accesskey="X" class="cancel" type="button" name="button" value="Cancelar" style="width:100px" onclick="window.history.back()">
                   </div>
                </td>
            </tr>

            <tr>
                <td colspan="2" class="detailedViewHeader">
                    <b>Datos Personales</b>
                </td>
            </tr>

            <!-- Added this file to display the fields in Create Entity page based on ui types  -->
            <tr style="height:25px">

                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"></font>C&oacute;digo
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input readonly="" name="codigo" style="border:1px solid #bababa; width:40%;" type="text" value="<?php echo $_smarty_tpl->getVariable('con_cod')->value;?>
">
                </td>

            </tr>

            <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"> * </font>Nombre
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="nombre" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo utf8_encode($_smarty_tpl->getVariable('nombre')->value);?>
">
                </td>

            </tr>
    
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"> * </font>Apellidos
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="apellidos" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo utf8_encode($_smarty_tpl->getVariable('apellidos')->value);?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red">  </font>Direcci&oacute;n
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="direccion" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo utf8_encode($_smarty_tpl->getVariable('direccion')->value);?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red">  </font>Fecha nacimiento
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="fechanac" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo $_smarty_tpl->getVariable('fechanac')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red">  </font>Celular
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="celular" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo $_smarty_tpl->getVariable('celular')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red">  </font>Tel&eacute;fono
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="telefono" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo $_smarty_tpl->getVariable('telefono')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"> * </font>E-mail
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="email" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo $_smarty_tpl->getVariable('email')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"></font>Facebook (username)
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <img class="redsocial_icon" title="Facebook" border="0" alt="Facebook" align="left" src="img/fb.jpg" width="14" height="14">
                    <input type="text" name="userfacebook" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:35%;" value="<?php echo $_smarty_tpl->getVariable('facebook')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"></font>Twitter (username)
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <img class="redsocial_icon" title="Twitter" border="0" alt="Facebook" align="left" src="img/twt.png" width="14" height="14">
                    <input type="text" name="usertwitter" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:35%;" value="<?php echo $_smarty_tpl->getVariable('twitter')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"></font>Recibe E-mail
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <label>   
                    <?php if ($_smarty_tpl->getVariable('recibemail')->value==''){?>
                        <input type="radio" name="recibemail"  value="1" checked="checked"/>
                    <?php }elseif($_smarty_tpl->getVariable('recibemail')->value=="1"){?>
                        <input type="radio" name="recibemail"  value="1" checked="checked"/>
                    <?php }elseif($_smarty_tpl->getVariable('recibemail')->value=="0"){?>
                        <input type="radio" name="recibemail"  value="1" />
                    <?php }?>
                    Si</label>

                    <label>
                    <?php if ($_smarty_tpl->getVariable('recibemail')->value==''){?>
                        <input type="radio" name="recibemail"  value="0" />
                    <?php }elseif($_smarty_tpl->getVariable('recibemail')->value=="1"){?>
                        <input type="radio" name="recibemail"  value="0" />
                    <?php }elseif($_smarty_tpl->getVariable('recibemail')->value=="0"){?>
                        <input type="radio" name="recibemail"  value="0" checked="checked" />
                    <?php }?>
                    No</label>
                </td>
           </tr>

           <tr style="height:25px">
                <!-- uitype 111 added for noneditable existing picklist values - ahmed -->
                <td width="30%" class="dvtCellLabel" align="right">
                        <font color="red"></font>
                        Empresa
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                <select name="lstempresas" tabindex="" class="small" style="width: 25%;">
                <?php if ($_smarty_tpl->getVariable('empresaactual')->value==null){?>
                    <option selected="selected" value="NULL">-----</option>
                <?php }?>
                <?php unset($_smarty_tpl->tpl_vars['smarty']->value['section']['i']);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['name'] = 'i';
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'] = is_array($_loop=$_smarty_tpl->getVariable('listaempresas')->value) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show'] = true;
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['max'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'] = 1;
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['start'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'] > 0 ? 0 : $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop']-1;
if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show']) {
    $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'];
    if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] == 0)
        $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show'] = false;
} else
    $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] = 0;
if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show']):

            for ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['start'], $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] = 1;
                 $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] <= $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'];
                 $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] += $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'], $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration']++):
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['rownum'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index_prev'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] - $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index_next'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] + $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['first']      = ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] == 1);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['last']       = ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] == $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total']);
?>
                <?php if ($_smarty_tpl->getVariable('empresaactual')->value==$_smarty_tpl->getVariable('listaempresas')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['emp_cod']){?>
                    <option value="<?php echo $_smarty_tpl->getVariable('listaempresas')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['emp_cod'];?>
" selected="selected"><?php echo utf8_encode($_smarty_tpl->getVariable('listaempresas')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['emp_nombre']);?>
</option>
                <?php }else{ ?>
                    <option value="<?php echo $_smarty_tpl->getVariable('listaempresas')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['emp_cod'];?>
"><?php echo utf8_encode($_smarty_tpl->getVariable('listaempresas')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['emp_nombre']);?>
</option>
                <?php }?>
                <?php endfor; endif; ?>
                </select>
                </td>
           </tr>
           <tr style="height:25px">
                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red">  </font>Cargo
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                    <input type="text" name="cargo" tabindex="" class="detailedViewTextBox" onfocus="this.className='detailedViewTextBoxOn'" onblur="this.className='detailedViewTextBox'" style="width:40%;" value="<?php echo $_smarty_tpl->getVariable('cargo')->value;?>
">
                </td>
           </tr>
           <tr style="height:25px">
                <!-- uitype 111 added for noneditable existing picklist values - ahmed -->
                <td width="30%" class="dvtCellLabel" align="right">
                        <font color="red"></font>
                        Origen de Contacto
                </td>

                <td width="70%" align="left" class="dvtCellInfo">
                <select name="lstorigencontactos" tabindex="" class="small" style="width: 25%;">
                <?php unset($_smarty_tpl->tpl_vars['smarty']->value['section']['i']);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['name'] = 'i';
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'] = is_array($_loop=$_smarty_tpl->getVariable('origencontactos')->value) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show'] = true;
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['max'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'] = 1;
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['start'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'] > 0 ? 0 : $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop']-1;
if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show']) {
    $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['loop'];
    if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] == 0)
        $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show'] = false;
} else
    $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'] = 0;
if ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['show']):

            for ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['start'], $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] = 1;
                 $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] <= $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total'];
                 $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] += $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'], $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration']++):
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['rownum'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index_prev'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] - $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index_next'] = $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['index'] + $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['step'];
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['first']      = ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] == 1);
$_smarty_tpl->tpl_vars['smarty']->value['section']['i']['last']       = ($_smarty_tpl->tpl_vars['smarty']->value['section']['i']['iteration'] == $_smarty_tpl->tpl_vars['smarty']->value['section']['i']['total']);
?>
                <?php if ($_smarty_tpl->getVariable('origenactual')->value==$_smarty_tpl->getVariable('origencontactos')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['ori_cod']){?>
                    <option value="<?php echo $_smarty_tpl->getVariable('origencontactos')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['ori_cod'];?>
" selected="selected"><?php echo utf8_encode($_smarty_tpl->getVariable('origencontactos')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['ori_descripcion']);?>
</option>
                <?php }else{ ?>
                    <option value="<?php echo $_smarty_tpl->getVariable('origencontactos')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['ori_cod'];?>
"><?php echo utf8_encode($_smarty_tpl->getVariable('origencontactos')->value[$_smarty_tpl->getVariable('smarty')->value['section']['i']['index']]['ori_descripcion']);?>
</option>
                <?php }?>
                <?php endfor; endif; ?>
                </select>
                </td>
           </tr>

           <tr style="height:20px">
               <td>&nbsp;</td>
           </tr>

           <tr>	
                <td colspan="2" class="detailedViewHeader">
                    <b>Información Adicional</b>
                </td>
           </tr>
            
           <tr style="height:25px">

                <td width="20%" class="dvtCellLabel" align="right">
                    <font color="red"></font>Descripci&oacute;n
                </td>
		
                <td colspan="2">
                    <textarea class="detailedViewTextBox" tabindex="" onfocus="this.className='detailedViewTextBoxOn'" name="descripcion" onblur="this.className='detailedViewTextBox'" cols="90" rows="8"><?php echo utf8_encode($_smarty_tpl->getVariable('descripcion')->value);?>
</textarea>
		</td>
            </tr>
                           
            <tr tyle="height:25px"><td>&nbsp;</td>
            </tr>
           
            <tr>
																				<td colspan="4" class="detailedViewHeader">
            <b>Informaci&oacute;n de Foto del Contacto:</b>
																				</td>
            </tr>

            <tr style="height:25px">

                <td width="30%" class="dvtCellLabel" align="right">
                    <font color="red"></font>Imagen del Contacto
                </td>
                <td colspan="2" width="70%" align="left" class="dvtCellInfo">
                    <?php if ($_smarty_tpl->getVariable('imagen')->value==null){?>
                        <input type="file" name="userfile">
                    <?php }else{ ?>
                        <div align="center" style="padding: 5px;"><img src="<?php echo $_smarty_tpl->getVariable('imagen')->value;?>
"  title="<?php echo utf8_encode($_smarty_tpl->getVariable('nombre')->value);?>
 <?php echo utf8_encode($_smarty_tpl->getVariable('apellidos')->value);?>
" border="0" alt="<?php echo utf8_encode($_smarty_tpl->getVariable('nombre')->value);?>
 <?php echo utf8_encode($_smarty_tpl->getVariable('apellidos')->value);?>
" width="120px" height="120px"></div>
                        <input type="hidden" name="userfile" value="<?php echo $_smarty_tpl->getVariable('imagen')->value;?>
">
                    <?php }?>
                </td>
                
            </tr>

            <tr>
		<td colspan="2" style="padding:10px 0px 10px 0px">
		<div align="center">
                    <input title="<?php echo $_smarty_tpl->getVariable('txtboton')->value;?>
 [Alt+S]" accesskey="S" class="save" type="submit" name="button" value="<?php echo $_smarty_tpl->getVariable('txtboton')->value;?>
" style="width:100px" onclick="return( formvalidacion());">
                    <input title="Cancelar [Alt+X]" accesskey="X" class="cancel" type="button" name="button" value="Cancelar" style="width:100px" onclick="window.history.back()">
		</div>
		</td>
            </tr>            
	</tbody>       
       </table>
    </form>
    </div>
   
</div>